//
//  MBProgressHUD+HUD.m
//  UserUse
//
//  Created by 李鹏霖 on 2017/2/15.
//  Copyright © 2017年 CJPC. All rights reserved.
//

#import "MBProgressHUD+HUD.h"

@implementation MBProgressHUD (HUD)
+(void)showTheMessage:(NSString *)message with:(UIView *)view
{
    UIView *showView;
    if (view) {
        showView = view;
    }
    else
    {
        showView = [UIApplication sharedApplication].keyWindow;
    }
    MBProgressHUD *hub = [MBProgressHUD showHUDAddedTo:showView animated:YES];
    hub.labelText = message;
    hub.mode = MBProgressHUDModeText;
    hub.removeFromSuperViewOnHide = YES;
    [hub hide:YES afterDelay:1];

}
@end
